<template>
  <div id="cesiumContainer"></div>
</template>
<script setup lang="ts">
onMounted(() => {
  initMap()
})
const initMap = () => {
  //1. 创建map实例
  const map = new window.CgsMap({
    target: 'cesiumContainer', //容器id
    projection: 'EPSG:102113', //地图投影
    center: [118.804, 32.864], // 设置中心点
    zoom: 11, //默认缩放
    mode: '3D', //初始化时的模式
    threeFlag: true, //开启3D
  })
  window.map = map
  map.loadConfig()
  map.setStarVisible(true) //显示星空
  map.setFogVisible(false) //不显示雾
}

</script>
<style lang="less" scoped>
#cesiumContainer {
  position: absolute;
  padding: 0px;
  margin: 0px;
  width: 100vw;
  height: 100vh;
}
</style>
